# coding: utf-8
from application import db

class Address(db.Model):
    __tablename__ = 't_address'

    id = db.Column(db.BigInteger, primary_key=True, unique=True, comment='序号')
    userAddress = db.Column(db.String(500), comment='用户地址')
    nickname = db.Column(db.String(500), comment='收货人姓名')
    mobile = db.Column(db.String(11), comment='收货人手机号码')
    province_id = db.Column(db.Integer, comment='省id')
    province_str = db.Column(db.String(50), comment='省名称')
    city_id = db.Column(db.Integer, comment='城市id')
    city_str = db.Column(db.String(50), comment='城市名称')
    area_id = db.Column(db.Integer, comment='区域id')
    area_str = db.Column(db.String(50), comment='区域名称')
    address = db.Column(db.String(100), comment='详细地址')
    status = db.Column(db.Integer, comment='状态')
    is_default = db.Column(db.Integer, comment='默认地址')
    updated_time = db.Column(db.DateTime, nullable=False, comment='更新时间')
    created_time = db.Column(db.DateTime, nullable=False, comment='创建时间')
